<!--SIF Implementation Specification 2.2-6 (March 17, 2008)-->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" targetNamespace="http://www.sifinfo.org/infrastructure/2.x" xmlns:sif="http://www.sifinfo.org/infrastructure/2.x" elementFormDefault="qualified">
  <xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="imports/xml/xml.xsd" />
  <xs:complexType name="PurchasingType">
    <xs:annotation>
      <xs:documentation>This object provides information down to the line item level for requisitions and purchase orders.</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="FormType" minOccurs="0">
        <xs:annotation>
          <xs:documentation>Type of purchasing document.</xs:documentation>
        </xs:annotation>
        <xs:simpleType>
          <xs:restriction base="xs:token">
            <xs:enumeration value="PO">
              <xs:annotation>
                <xs:documentation>Purchase order</xs:documentation>
              </xs:annotation>
            </xs:enumeration>
            <xs:enumeration value="REQ">
              <xs:annotation>
                <xs:documentation>Requisition</xs:documentation>
              </xs:annotation>
            </xs:enumeration>
          </xs:restriction>
        </xs:simpleType>
      </xs:element>
      <xs:element name="FormNumber" minOccurs="0" type="xs:normalizedString">
        <xs:annotation>
          <xs:documentation>Requisition or PO number.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="FiscalYearRefId" minOccurs="0" nillable="true" type="sif:IdRefType">
        <xs:annotation>
          <xs:documentation>Reference to fiscal year for the transaction.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="VendorInfoRefId" minOccurs="0" nillable="true" type="sif:IdRefType">
        <xs:annotation>
          <xs:documentation>This object references the VendorInfo object and should be considered mandatory when FormType="PO"</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="LocationInfoRefId" minOccurs="0" nillable="true" type="sif:IdRefType">
        <xs:annotation>
          <xs:documentation>The building ID for this purchasing activity.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="EmployeePersonalRefId" minOccurs="0" nillable="true" type="sif:IdRefType">
        <xs:annotation>
          <xs:documentation>The employee ID for the originator of this purchasing activity.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="PurchasingItems" minOccurs="0">
        <xs:complexType>
          <xs:sequence>
            <xs:element name="PurchasingItem" minOccurs="0" maxOccurs="unbounded">
              <xs:complexType>
                <xs:sequence>
                  <xs:element name="ItemNumber" minOccurs="0" nillable="true" type="xs:normalizedString">
                    <xs:annotation>
                      <xs:documentation>Vendor item number.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                  <xs:element name="ItemDescription" minOccurs="0" type="xs:string">
                    <xs:annotation>
                      <xs:documentation>Description of the item.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                  <xs:element name="Quantity" minOccurs="0" nillable="true" type="xs:normalizedString">
                    <xs:annotation>
                      <xs:documentation>Quantity ordered.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                  <xs:element name="UnitCost" minOccurs="0" nillable="true" type="sif:MonetaryAmountType">
                    <xs:annotation>
                      <xs:documentation>Unit cost of the item.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                  <xs:element name="ExpenseAccounts" minOccurs="0" nillable="true">
                    <xs:complexType>
                      <xs:sequence>
                        <xs:element name="ExpenseAccount" minOccurs="0" maxOccurs="unbounded">
                          <xs:complexType>
                            <xs:sequence>
                              <xs:element name="AccountCode" minOccurs="0" type="xs:token">
                                <xs:annotation>
                                  <xs:documentation>Account code charged to this item.</xs:documentation>
                                </xs:annotation>
                              </xs:element>
                              <xs:element name="Amount" minOccurs="0" type="sif:MonetaryAmountType">
                                <xs:annotation>
                                  <xs:documentation>Amount charged to this account.</xs:documentation>
                                </xs:annotation>
                              </xs:element>
                            </xs:sequence>
                          </xs:complexType>
                        </xs:element>
                      </xs:sequence>
                    </xs:complexType>
                  </xs:element>
                </xs:sequence>
              </xs:complexType>
            </xs:element>
          </xs:sequence>
        </xs:complexType>
      </xs:element>
      <xs:element name="SIF_Metadata" minOccurs="0" nillable="true" type="sif:SIF_MetadataType" />
      <xs:element name="SIF_ExtendedElements" minOccurs="0" nillable="true" type="sif:SIF_ExtendedElementsType" />
    </xs:sequence>
    <xs:attribute name="RefId" use="required" type="sif:RefIdType">
      <xs:annotation>
        <xs:documentation>Transaction GUID for this purchasing activity. The application that owns this object and is responsible for generating this unique ID.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
  </xs:complexType>

  <xs:element name="Purchasing" type="sif:PurchasingType" />

</xs:schema>